Quick Navigation All projects Hardware Links Top projectsAlan numitron clock Clapclap 2313/1386 SNES Pi Webserver USB Volume/USB toys Smokey amp Laser cutter WordClock ardReveil v3 SNES Arcade cabinet Game boy projects cameleon Home Presence Detector GitHubAlanFromJapan Contact me![]() Who's Alan?Akizukidenshi Elec-lab Rand Nerd Tut EEVblog SpritesMods AvrFreaks Gameboy Dev FLOZz' blog Switch-science Sparkfun Suzusho Datasheet Lib Reddit Elec Ermicro Carnet du maker (fr) |
USB Volume ControlLast update: Sat Jan 10 23:04:54 2026
Disclaimer: this is just my recreation of the one found here http://obruboff.ru/english-pages/usb-volume-control/. All credits go to him, many thanks for sharing! Спасибо!Software: USB without Arduino Hardware: RapideUSB PresentationPrinciplePoints of interrest Important subtlety I didn't get at first: we implement a "Consumer device" not a "Keyboard"! Hence my surprise that the codes for the Volume control on Keyboard and the ones implemented were different (see the HID doc chapter 10 vs. chapter 15).Good thing is there are lots of nice functions possible to implement too, like a "Next" button that I'm much more interrested to bind to the click of the rotary encoder to that rather than mute. Alternate version 3 buttonsLate December 2019 I changed my keyboard to one I like but has no media keys, so I made a 3 buttons one for mute/vol+/vol- and on LInux/Eclipse.SchematicsBill of materials
ImplementationCheapo encoderBoth wires A and B are pulled UP with a 10k resistor, the middle pin (C) is grounded. I might have got the direction wrong, I do that from memory, but you get the jist.
____ _____|_____ ___
A \________/ | \________/
_______ __|__ ______
B \________/ | \________/
|
Left Right
Source codeAs usual in GitHub:Pictures![]() In built status box... it's a cypress block carved inside ![]() With its perfectly rounded pao-santo button. Lineseed oil finish. ![]() //Another version for another PC with 3 buttons: sound up/down/mute, with its enclosure // LinksHelpful sourcesInspiration |
|
All content on this site is shared under the MIT licence (do what u want, don't sue me, hat tip appreciated) electrogeek.tokyo ~ Formerly known as Kalshagar.wikispaces.com and electrogeek.cc (AlanFromJapan [2009 - 2026]) |
|